package net.orange.architecture.db;

/**
 * The order (ascending/descending)
 */
public class Order {

	/**
	 * Ascending
	 */
	public final static int ASC = 0;

	/**
	 * Descending
	 */
	public final static int DESC = 1;

	/**
	 * The field name
	 */
	private String FieldName;

	/**
	 * The order (ascending/descending)
	 */
	private int OrderBy;

	/**
	 * The constructor with the field name and order
	 * @param f The field name
	 * @param o The order
	 */
	public Order(String f, int o) {
		super();
		FieldName = f;
		OrderBy = o;
	}

	/**
	 * @return Returns the fieldName.
	 */
	public String getFieldName() {
		return FieldName;
	}

	/**
	 * @return Returns the orderBy.
	 */
	public int getOrderBy() {
		return OrderBy;
	}

	/**
	 * @param fieldName
	 *            The fieldName to set.
	 */
	public void setFieldName(String fieldName) {
		FieldName = fieldName;
	}

	/**
	 * @param orderBy
	 *            The orderBy to set.
	 */
	public void setOrderBy(int orderBy) {
		OrderBy = orderBy;
	}
}